package com.zlp.alipay.service;

import com.alipay.api.AlipayApiException;
import com.baomidou.mybatisplus.extension.service.IService;
import com.zlp.alipay.dto.OrderReq;
import com.zlp.alipay.dto.RefundReq;
import com.zlp.alipay.model.Order;

import javax.servlet.http.HttpServletRequest;

/**
 * @author Devin Zhang
 * @className OrderService
 * @date 2020/5/12 10:53
 */


public interface OrderService extends IService<Order> {

    /** 
     * 订单支付
     * @param orderReq
     * @date: 2021/11/4 10:37
     * @return: java.lang.String 
     */
    String orderPay(OrderReq orderReq);

    /**
     * 支付成功的回调接口
     */
    /** 
     * 支付成功的回调接口
     * @param request
     * @date: 2021/11/4 11:04
     * @return: java.lang.String 
     */
    String notifyPayResult(HttpServletRequest request);

    
    /** 
     * 根据订单号获取订单信息
     * @param orderNo
     * @date: 2021/11/4 11:12
     * @return: com.zlp.pay.model.Order 
     */
    Order getOrderByOrderNo(String orderNo);

    /** 
     * 支付退款
     * @param refundReq
     * @date: 2021/11/4 13:25
     * @return: java.lang.String 
     */
    String refund(RefundReq refundReq) ;

}
